<?php
namespace app\model;

use think\Validate;

class AccountValidator extends Validate
{
    protected $rule = [
        'username'  =>  'require|max:255',
        'password|密码' =>  'require|max:255'
    ];
    protected $message = [
        'username.require' => '用户名不能为空'
    ];

}